package com.howtoplay.gateserver.Bean;

public class Response {

    private Boolean success;
    private Object data;

    public static Response ErrorResonse(String msg){
        return new Response(false,msg);
    }

    public static Response SuccessResonse(Object msg){
        return new Response(true,msg);
    }



    public Response(Boolean success, Object data) {
        this.success = success;
        this.data = data;
    }

    public Boolean getSuccess() {
        return success;
    }

    public void setSuccess(Boolean success) {
        this.success = success;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }

    @Override
    public String toString() {
        return "Response{" +
                "success=" + success +
                ", data=" + data +
                '}';
    }
}
